package com.fengniaoxls.fengniaonewretail.jpush.voice;

import android.content.res.AssetFileDescriptor;
import android.content.res.AssetManager;

import com.fengniaoxls.fengniaonewretail.app.App;

import java.io.IOException;

/**
 *
 * @author Administrator
 * @date 2018/10/9
 */

public class FileUtils {

    public static AssetFileDescriptor getAssetFileDescription(String filename) throws IOException {
        AssetManager manager = App.getInstance().getApplicationContext().getAssets();
        return manager.openFd(filename);
    }

    public static String getAssetsPath(String filename) {
        return "file:///android_asset/" + filename;
    }
}
